<template>
	<el-container style="height: 480px">
		<el-header>
			<el-form
				inline
				label-width="49px"
				:model="queryList"
				style="margin-top: 5px; width: 100%"
			>
				<el-input
					v-model="queryList.Code"
					placeholder="请输入签送组编码"
					style="width: 180px"
				></el-input>
				&nbsp;
				<el-input
					v-model="queryList.Name"
					placeholder="请输入签送组名称"
					style="width: 150px"
				></el-input>
				&nbsp;
				
				<el-button type="primary" @click="$refs.mytable.getData()"
					>查询</el-button
				>
			</el-form>
		</el-header>
		<el-foot>
			<scTable
				ref="mytable"
				:data="listData"
				:attrList="attrList"
				:valueList="valueList"
				:queryList="queryList"
				:sort-orders="['ascending', 'descending']"
				@selection-change="selectionChange"
				row-key="Code"
				key="Code"
				stripe
				:hideDo="true"
				height="480px"
				style="max-height: 480px; min-width: 420"
			>
				<el-table-column type="selection" width="50"></el-table-column>
				<el-table-column
					type="index"
					label="序号"
					prop="rownumber"
					width="50"
				></el-table-column>
				<el-table-column
					label="编号"
					prop="GroupCode"
					width="200"
					sortable
				></el-table-column>
				<el-table-column
					label="名称"
					prop="GroupName"
					width="250"
					sortable
				></el-table-column>
				 </scTable
		></el-foot>
	</el-container>
</template>

<script>
import publicjs from "@/api/model/publicjs";
export default {
	name: "typelist",
	components: {
		publicjs,
	},
	data() {
		return {
			selectionRows: [],
			pkList: ["Code"],
			attrList: {
				Name: "PosPermissionGroup",
				UseDistinct: false,
				OrgCode: "",
				UseBackUp: false,
				UseGroup: false,
			},
			valueList: {
				GroupCode: "GroupCode",
                GroupName: "GroupName",
			},
			queryList: {
				Code: "",
				Name: ""
			},
			result: "", // 运行结果
			props1: {
				checkStrictly: true,
				emitPath: false,
			},
			optionsUomCode: [],
		};
	},
	methods: {
		//表格选择后回调事件
		selectionChange(selection) {
			// eslint-disable-next-line no-debugger
			//debugger;
			this.selectionRows = selection;
		},

		async opBindData() {
			this.$refs.mytable.clearSort();
			this.$refs.mytable.getData();
		},

		
		
	},
	async mounted() {
		await this.opBindData();
	},
};
</script>
